package org.itboys.core.service.mongo.front;

import org.itboys.core.common.SundayCommonConstants;
import org.itboys.core.dto.count.SundayCountDto;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

/**
 * 作者：zzq
 * 时间：2018/10/23
 * 描述：结算
 */
@Service
public class SundayFrontCountService {
    @Autowired
    private SundayFrontCartService cartService;

    /**
     * 结算购物车  用来结算除基本商品外的信息
     * @param memberId
     * @param cartIds
     * @param cartType
     * @return
     */
    public SundayCountDto countCart(Long memberId, List<Long> cartIds, Integer cartType,Integer status) {
        SundayCountDto countDto = cartService.getCart(memberId, cartIds, cartType,status);
      /*  Double totalAmount=countDto.getTotalAmount();
        Double payAmount=countDto.getPayAmount();
        //默认信息
        countDto.setSendAmount(0.0);
        countDto.setTotalAmount(totalAmount);
        countDto.setPayAmount(payAmount);*/
        return countDto;
    }


}
